/** 添加系统设置信息 */
(function(window, owner) {
	/** 配置数据缓存标识 */
	owner.cache_dataconfig = "cache_dataconfig";
	/** 配置数据缓存标识 */
	owner.cache_planconfig = "cache_planconfig";
	/** 服务器接口地址 */
	owner.GetServerURL = function() {
		//return "http://localhost:26416/";
		return "http://124.232.165.93:34881/";
	}
	/** 获取配置数据地址 */
	owner.GetConfigData = function(uid) {
		return this.GetServerURL() + "displaydirectory/getdisplaydirectorylistbyuser?userid=" + uid;
	}
	/** 获取计划配置数据地址 */
	owner.GetPlanConfig = function(uid, pid) {
		return this.GetServerURL() + "plan/getdetailedplandata?userid=" + uid + "&powerid=" + pid +
			"&pageindex=1&pagesize=100";
	}
	/** 获取缓存配置信息 */
	owner.GetCacheConfig = function() {
		var str = localStorage.getItem(owner.cache_dataconfig);
		if (str != "" && str != null) {
			return JSON.parse(str);
		} else {
			return null;
		}
	}
	/** 设置缓存配置信息 */
	owner.SetCacheConfig = function(o) {
		if (o)
			localStorage.setItem(owner.cache_dataconfig, JSON.stringify(o));
	}
	/** 获取缓存计划配置信息 */
	owner.GetPlanDataConfig = function() {
		var str = localStorage.getItem(owner.cache_planconfig);
		if (str != "" && str != null) {
			return JSON.parse(str);
		} else {
			return null;
		}
	}
	/** 设置缓存计划配置信息 */
	owner.SetPlanDataConfig = function(o) {
		if (o)
			localStorage.setItem(owner.cache_planconfig, JSON.stringify(o));
	}
}(window, window.setting = {}))
